package test00.test01;

/**
 * 匿名内部类 实现
 * @Author lzp
 * @Date 2024-04-09
 */
public class test02 {
    public static void main(String[] args) {

        //匿名内部类 实现
         YunSuan yunSuan = new YunSuan() {
             @Override
             public int sum(int a, int b) {
                 return a+b;
             }
         };
        System.out.println(yunSuan.sum(100, 1000));
    }
}
